import { boot } from "quasar/wrappers";
import { createI18n } from "vue-i18n";
import messages from "src/i18n";

export const i18n = createI18n({
  locale: "zh-CN",
  fallbackLocale: "en-US",
  legacy: false,
  messages,
  silentTranslationWarn: true,
  silentFallbackWarn: true,
  globalInjection: true,
});

export default boot(({ app, store }) => {
  // Set i18n instance on app
  app.use(i18n);
});
